<template>
  <div>
    <table border="1" cellspacing="0">
      <tr>
        <td>图书</td>
        <td>价格</td>
      </tr>
      <tr v-for="i in book">
        <td>{{ i.name }}</td>
        <td>{{ i.price }}</td>
      </tr>

    </table>

  </div>
</template>

<script>
export default {
  name: "get_cate1",
  data() {
    return {
      id: this.$route.query.id,
      book: []
    }
  },
  methods: {
    get_cate1() {
      this.$axios.get('cate/?id=' + this.id)
        .then(res => {
          this.book = res.data.list

        })
    }

  },
  mounted() {
    this.get_cate1()
  }
}
</script>

<style scoped>

</style>
